﻿Public Class form
    Dim go_name_id As String
    Dim go_entry_id As Long
    Dim go_display_id As Long
    Dim go_typ_id As Byte
    Dim go_backup As String


    Private Sub form_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load

    End Sub

    Private Sub TabPage1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles GameObject.Click

    End Sub

    Private Sub TabControl1_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles TabControl1.SelectedIndexChanged

    End Sub

    Private Sub ComboBox1_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles go_typ.SelectedIndexChanged

    End Sub

    Private Sub go_button_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles go_button.Click
        If (go_name.Text = "") Then
            go_output_info.Text = "Fehler beim erstellen, bitte schau ob alle Felder ausgefüllt sind!"
        ElseIf (go_entry.Text = "") Then
            go_output_info.Text = "Fehler beim erstellen, bitte schau ob alle Felder ausgefüllt sind!"
        ElseIf (go_display.Text = "") Then
            go_output_info.Text = "Fehler beim erstellen, bitte schau ob alle Felder ausgefüllt sind!"
        ElseIf (go_typ.Text = "") Then
            go_output_info.Text = "Fehler beim erstellen, bitte schau ob alle Felder ausgefüllt sind!"
        Else
            go_output_info.Text = "Vorgang erfolgreich"
            go_name_id = go_name.Text
            go_entry_id = go_entry.Text
            go_display_id = go_display.Text


            If (go_typ.Text = "Tür") Then
                go_typ_id = 0
            ElseIf (go_typ.Text = "Schalter") Then
                go_typ_id = 1
            ElseIf (go_typ.Text = "Questgeber") Then
                go_typ_id = 2
            ElseIf (go_typ.Text = "Kiste") Then
                go_typ_id = 3
            ElseIf (go_typ.Text = "Generel") Then
                go_typ_id = 5
            ElseIf (go_typ.Text = "Falle") Then
                go_typ_id = 6
            ElseIf (go_typ.Text = "Stuhl") Then
                go_typ_id = 7
            ElseIf (go_typ.Text = "Zauberziel") Then
                go_typ_id = 8
            ElseIf (go_typ.Text = "Text") Then
                go_typ_id = 9
            ElseIf (go_typ.Text = "Transport (Map)") Then
                go_typ_id = 11
            ElseIf (go_typ.Text = "Transport (Map zu Map)") Then
                go_typ_id = 15
            ElseIf (go_typ.Text = "Flächenschaden") Then
                go_typ_id = 12
            ElseIf (go_typ.Text = "Duellflagge") Then
                go_typ_id = 16
            ElseIf (go_typ.Text = "Angeln") Then
                go_typ_id = 17
            ElseIf (go_typ.Text = "Ritual") Then
                go_typ_id = 18
            ElseIf (go_typ.Text = "Postbox") Then
                go_typ_id = 19
            ElseIf (go_typ.Text = "Auktionshaus") Then
                go_typ_id = 20
            ElseIf (go_typ.Text = "Wachposten") Then
                go_typ_id = 21
            ElseIf (go_typ.Text = "Spell Caster") Then
                go_typ_id = 22
            ElseIf (go_typ.Text = "Gildentresor") Then
                go_typ_id = 34
            Else
                go_output_info.Text = "Bitte Überprüfen sie den GameObject Typ!"
            End If
            go_output.Text = "insert  into `gameobject_names`(`entry`,`Type`,`DisplayID`,`Name`,`spellfocus`,`sound1`,`sound2`,`sound3`,`sound4`,`sound5`,`sound6`,`sound7`,`sound8`,`sound9`,`unknown1`,`unknown2`,`unknown3`,`unknown4`,`unknown5`,`unknown6`,`unknown7`,`unknown8`,`unknown9`,`unknown10`,`unknown11`,`unknown12`,`unknown13`,`unknown14`)" & "values (" & go_entry_id & "," & go_display_id & "," & go_typ_id & ",'" & go_name_id & "',0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0);"
            go_backup = go_output.Text
        End If


    End Sub


End Class
